import Vue from 'vue'
import VueRouter from 'vue-router'
import LoginReg from '../views/LoginReg.vue'
import InvalidRoute from '../views/InvalidRoute.vue'
import HrPanel from '../views/HrPanel.vue'
import ShipMSLogin from '../views/ShipMSLogin.vue'
Vue.use(VueRouter)

const routes = [
  {
    path:"/",
    redirect:"/ship_login_panel",
  },
  {
    path:"/ship_login_panel",
    name:"ship_login_panel",
    component:ShipMSLogin
  },
  {
    path:"/hr_panel",
    name:"hr_panel",
    component:HrPanel
  },
  {
    path: "/reg_login_page",
    name: "reg_login_page",
    component: LoginReg
  },
  {
    path:"/*",
    name:"invalid route",
    component: InvalidRoute
  }
]

const router = new VueRouter({
  mode: 'history',
  base: process.env.BASE_URL,
  routes
})

export default router
